home *** CD-ROM | disk | FTP | other *** search
/ Info-Mac 4 / Info_Mac IV CD-ROM (Pacific HiTech Inc.)(August 1994).iso / Science / RLaB / help / srand < prev    next >
Text File  |  1994-04-25  |  430b  |  20 lines

  1. srand:
  2.  
  3. Syntax:    srand ( )
  4.     srand ( a )
  5.     srand ( "clock" )
  6.  
  7. Description:
  8.  
  9.     Srand sets the seed for the random number generator.
  10.     `srand()' sets the seed to the original value (the last value
  11.     given to srand(), or the default value, 1).
  12.  
  13.     `srand( "clock" )' sets the seed based upon the machines clock
  14.     value. This provides users a way of picking a unique seed each
  15.     time.
  16.  
  17.     Srand uses the RANLIB subroutine SETALL.
  18.  
  19. See Also: rand
  20.